cmake_minimum_required(VERSION 2.8)
set(TARGET ubtech_tts3)
project(${TARGET})

set(CMAKE_CXX_STANDARD 14)
set(CMAKE_SYSTEM_NAME Linux)


include_directories(
	${PROJECT_SOURCE_DIR}/include/
)


aux_source_directory(./src/front/ SOURCES)
aux_source_directory(./src/front_text/ SOURCES)
aux_source_directory(./src/absl2/base/internal/ SOURCES)
aux_source_directory(./src/absl2/strings/ SOURCES)
aux_source_directory(./src/absl2/strings/internal/ SOURCES)
aux_source_directory(./src/cppjieba/ SOURCES)

aux_source_directory(./src/sql/ SOURCES)

aux_source_directory(./src/predictor/ SOURCES)

link_libraries(pthread)
link_libraries(dl)

# 3. compile options 
add_definitions(-std=c++11 -g -O3 -pthread)
set(EXECUTABLE_OUTPUT_PATH ${PROJECT_SOURCE_DIR})
set(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR})

add_library(front SHARED ${SOURCES}) 

# 4.add executable output
add_executable(${TARGET} main.cpp  ${SOURCES})

#target_link_libraries(${TARGET}  -liomp5  -ldl)
target_link_libraries(${TARGET}  -ldl)
